import request from '@/utils/request'

export const addOneGoodsCategory = data => request({
  url: '/addOneGoodsCategory',
  method: 'put',
  data: data || {}
})

export const deleteOneGoodsCategory = id => request({
  url: '/deleteOneGoodsCategory/' + id,
  method: 'delete'
})

export const updateOneGoodsCategory = data => request({
  url: '/updateOneGoodsCategory',
  method: 'patch',
  data: data || {}
})

export const getOneGoodsCategory = id => request({
  url: '/getOneGoodsCategory/' + id,
  method: 'get'
})

export const getGoodsCategoryList = data => request({
  url: '/getGoodsCategoryList',
  method: 'post',
  data: data || {}
})

export const getAllGoodsCategoryList = () => request({
  url: '/getAllGoodsCategoryList',
  method: 'get'
})

